<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<html>
<head>
<base href="<%=basePath%>">
<title>注册页面</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<link rel="stylesheet" type="text/css" href="${base}/css/bootstrap.css">
<link href="${base}/css/font-awesome.css?v=4.4.0" rel="stylesheet">
<!-- Sweet Alert -->
<link href="${base}/css/plugins/sweetalert/sweetalert.css"
	rel="stylesheet">
<link href="${base}/css/animate.css" rel="stylesheet">
<link rel="stylesheet" type="text/css"
	href="${base}/css/jquery.searchableSelect.css">

<script type="text/javascript" src="${base}/js/jquery-3.1.0.js"></script>
<script type="text/javascript" src="${base}/js/bootstrap.js"></script>
<script src="${base}/js/content.js?v=1.0.0"></script>
<script type="text/javascript"
	src="${base}/js/jquery.searchableSelect.js"></script>
</head>


<body>
	<div class="container">
	

		

				<div class="col-md-8"
					style="background: #fff; padding: 40px 80px; margin: 30px; border: 7px solid #ccc;">

					<form class="form-horizontal" role="form">
						<div class="form-group">
							<label for="memberName123" class="col-sm-2 control-label">成员姓名:</label>
							<div class="col-sm-6">
								<input type="hidden" name="projectId" value="${project.id }">
								<select id="memberName123" name="memberName">

									<option value="">请选择或者输入成员姓名</option>
									<c:forEach items="${users}" var="user">
										<option value="${user.name }">${user.name }</option>
									</c:forEach>
								</select>
							</div>
						</div>

					</form>
					<div>
						<button class="btn btn-info" onclick="select()">选择</button>
					</div>
				</div>


			</div>
		</div>
		
</body>
<script type="text/javascript">
	$(function() {

		$('#memberName123').searchableSelect();
	});
	var index = parent.layer.getFrameIndex(window.name);
	function select() {
		

		var member = $('#memberName123').val();
		parent.$("." + parent.data).attr("editor", member);
		parent.$("." + parent.data).attr("placeholder", member+"<编辑>");
		parent.$("#" + parent.data).val(member);
		
		parent.$("#" + parent.data).attr("name",parent.data);
	
		
		parent.layer.close(index);
	}
</script>
</html>


